import Vue from "vue";
import Vuex from "vuex";
Vue.use(Vuex);

const store = new Vuex.Store({
  //存储token
  state: {
    token: "",
  },
  //   修改token状态
  mutations: {
    saveToken: (state, payload) => {
      state.token = payload;
    },
  },
});
export default store;
